package com.tjzx.entity;

/**
 * EipUnitedDeptEmpId entity. @author MyEclipse Persistence Tools
 */

public class EipUnitedDeptEmpId implements java.io.Serializable {

	// Fields

	private EipUnitedEmployee eipUnitedEmployee;
	private EipUnitedDepartment eipUnitedDepartment;

	// Constructors

	/** default constructor */
	public EipUnitedDeptEmpId() {
	}

	/** full constructor */
	public EipUnitedDeptEmpId(EipUnitedEmployee eipUnitedEmployee,
			EipUnitedDepartment eipUnitedDepartment) {
		this.eipUnitedEmployee = eipUnitedEmployee;
		this.eipUnitedDepartment = eipUnitedDepartment;
	}

	// Property accessors

	public EipUnitedEmployee getEipUnitedEmployee() {
		return this.eipUnitedEmployee;
	}

	public void setEipUnitedEmployee(EipUnitedEmployee eipUnitedEmployee) {
		this.eipUnitedEmployee = eipUnitedEmployee;
	}

	public EipUnitedDepartment getEipUnitedDepartment() {
		return this.eipUnitedDepartment;
	}

	public void setEipUnitedDepartment(EipUnitedDepartment eipUnitedDepartment) {
		this.eipUnitedDepartment = eipUnitedDepartment;
	}

	public boolean equals(Object other) {
		if ((this == other))
			return true;
		if ((other == null))
			return false;
		if (!(other instanceof EipUnitedDeptEmpId))
			return false;
		EipUnitedDeptEmpId castOther = (EipUnitedDeptEmpId) other;

		return ((this.getEipUnitedEmployee() == castOther
				.getEipUnitedEmployee()) || (this.getEipUnitedEmployee() != null
				&& castOther.getEipUnitedEmployee() != null && this
				.getEipUnitedEmployee()
				.equals(castOther.getEipUnitedEmployee())))
				&& ((this.getEipUnitedDepartment() == castOther
						.getEipUnitedDepartment()) || (this
						.getEipUnitedDepartment() != null
						&& castOther.getEipUnitedDepartment() != null && this
						.getEipUnitedDepartment().equals(
								castOther.getEipUnitedDepartment())));
	}

	public int hashCode() {
		int result = 17;

		result = 37
				* result
				+ (getEipUnitedEmployee() == null ? 0 : this
						.getEipUnitedEmployee().hashCode());
		result = 37
				* result
				+ (getEipUnitedDepartment() == null ? 0 : this
						.getEipUnitedDepartment().hashCode());
		return result;
	}

}